import 'dart:convert';
/// code : 0
/// data : {"success":0,"challenge":"","requestId":"","newCaptcha":"","userId":"","imgCaptcha":"","gt":""}
/// msg : ""
/// serverTime : ""

GeekRegisterData geekRegisterDataFromJson(String str) => GeekRegisterData.fromJson(json.decode(str));
String geekRegisterDataToJson(GeekRegisterData data) => json.encode(data.toJson());
class GeekRegisterData {
  GeekRegisterData({
      int? code, 
      Data? data, 
      String? msg, 
      String? serverTime,}){
    _code = code;
    _data = data;
    _msg = msg;
    _serverTime = serverTime;
}

  GeekRegisterData.fromJson(dynamic json) {
    _code = json['code'];
    _data = json['data'] != null ? Data.fromJson(json['data']) : null;
    _msg = json['msg'];
    _serverTime = json['serverTime'];
  }
  int? _code;
  Data? _data;
  String? _msg;
  String? _serverTime;
GeekRegisterData copyWith({  int? code,
  Data? data,
  String? msg,
  String? serverTime,
}) => GeekRegisterData(  code: code ?? _code,
  data: data ?? _data,
  msg: msg ?? _msg,
  serverTime: serverTime ?? _serverTime,
);
  int? get code => _code;
  Data? get data => _data;
  String? get msg => _msg;
  String? get serverTime => _serverTime;

  Map<String, dynamic> toJson() {
    final map = <String, dynamic>{};
    map['code'] = _code;
    if (_data != null) {
      map['data'] = _data?.toJson();
    }
    map['msg'] = _msg;
    map['serverTime'] = _serverTime;
    return map;
  }

}

/// success : 0 流程正常、异常标识；1表示正常，0表示异常、后续走宕机模式
/// challenge : "" 流水号
/// requestId : "" 请求id 用来标识某一次请求 串联起注册与验证 两个环节
/// newCaptcha : "" 新版验证码标识
/// userId : "" 系统用户标识(脱敏过的),未登录会返回随机的标识串
/// imgCaptcha : "" 图形验证码数据，宕机模式返回
/// gt : "" 向极验申请的账号id

Data dataFromJson(String str) => Data.fromJson(json.decode(str));
String dataToJson(Data data) => json.encode(data.toJson());
class Data {
  Data({
      int? success, 
      String? challenge, 
      String? requestId,
      bool? newCaptcha,
      String? userId, 
      String? imgCaptcha, 
      String? gt,}){
    _success = success;
    _challenge = challenge;
    _requestId = requestId;
    _newCaptcha = newCaptcha;
    _userId = userId;
    _imgCaptcha = imgCaptcha;
    _gt = gt;
}

  Data.fromJson(dynamic json) {
    _success = json['success'];
    _challenge = json['challenge'];
    _requestId = json['requestId'];
    _newCaptcha = json['newCaptcha'];
    _userId = json['userId'];
    _imgCaptcha = json['imgCaptcha'];
    _gt = json['gt'];
  }
  int? _success;
  String? _challenge;
  String? _requestId;
  bool? _newCaptcha;
  String? _userId;
  String? _imgCaptcha;
  String? _gt;
Data copyWith({  int? success,
  String? challenge,
  String? requestId,
  bool? newCaptcha,
  String? userId,
  String? imgCaptcha,
  String? gt,
}) => Data(  success: success ?? _success,
  challenge: challenge ?? _challenge,
  requestId: requestId ?? _requestId,
  newCaptcha: newCaptcha ?? _newCaptcha,
  userId: userId ?? _userId,
  imgCaptcha: imgCaptcha ?? _imgCaptcha,
  gt: gt ?? _gt,
);
  int? get success => _success;
  String? get challenge => _challenge;
  String? get requestId => _requestId;
  bool? get newCaptcha => _newCaptcha;
  String? get userId => _userId;
  String? get imgCaptcha => _imgCaptcha;
  String? get gt => _gt;

  Map<String, dynamic> toJson() {
    final map = <String, dynamic>{};
    map['success'] = _success;
    map['challenge'] = _challenge;
    map['requestId'] = _requestId;
    map['newCaptcha'] = _newCaptcha;
    map['userId'] = _userId;
    map['imgCaptcha'] = _imgCaptcha;
    map['gt'] = _gt;
    return map;
  }

}